package top.mczhengyi.learn.helloworld02.controller;

import lombok.extern.log4j.Log4j;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import top.mczhengyi.learn.helloworld02.bean.Person;

@Slf4j
@RestController
public class Controller {
    @Autowired
    private Person person;
    @RequestMapping("/person")
    public Person getPerson() {
        log.info("Get Person: " + person);
        return person;
    }
}
